//
//  HNNewsMainCollectionViewCell.m
//  HappyNews
//
//  Created by Sai on 15/12/28.
//  Copyright © 2015年 bai wang. All rights reserved.
//

#import "HNNewsMainCollectionViewCell.h"

@implementation HNNewsMainCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    
    if (self) {
        
        // 添加控件
        CGFloat height = frame.size.height;
        CGFloat width = frame.size.width;
        
       _NewsMainImageView = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, width, height)];
        
        _NewsMainImageView.backgroundColor = [UIColor redColor];
        
        [self.contentView addSubview:_NewsMainImageView];
        
        _NewsMainClass = [[UILabel alloc]initWithFrame:CGRectMake(10, height - 30, width, 30)];
//        _NewsMainClass.text = @"分类选择";
        _NewsMainClass.font = [UIFont systemFontOfSize:20 weight:2];
        _NewsMainClass.textColor = [UIColor whiteColor];
        
        [self.contentView addSubview:_NewsMainClass];
        
    }
    return self;
}

- (void)setNewsMainClass:(UILabel *)NewsMainClass
{
    _NewsMainClass.text =(NSString *) NewsMainClass;
}








@end
